﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="LearnJquery._Default" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>

    <script type="text/javascript" src="js/jquery-1.4.2.js"></script>

    <script type="text/javascript">
        function checkObject() {
            var object = null;
            var result = (!object);
            alert("null 对象--为" + result);

            object = "";
            result = (!object);
            alert("空字符串-- 为" + result);

            object = undefined;
            result = (!object);
            alert("undefined 对像为--" + result);
        }
    </script>

</head>
<body>
    <form id="form1" runat="server">
    <div>
        <input type="button" value="CheckObject" id="button1" onclick="checkObject()" />

        <script type="text/javascript">
            //alert($("div").length);
            //alert($("#button1").selector);
            var callBack = $(function($) {
            var button = $("#button1");
                button.val("aaa");
            });
        </script>

    </div>
    </form>
</body>
</html>
